package com.atguigu.gmall.list.client;

import com.atguigu.gmall.common.result.Result;
import com.atguigu.gmall.list.model.SearchParam;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@FeignClient(value = "service-list",fallback = ListDegradbFeignClient.class)
public interface ListFeignClient {


    @GetMapping("/api/list/inner/incrHotScore/{skuId}")
    public void innerScore(@PathVariable("skuId")Long skuId);
    /**
     * 商品的检索
     * @param searchParam
     * @return
     */
    @PostMapping("/api/list/")
    public Result search(@RequestBody SearchParam searchParam);
}
